package com.ln.prac.base.xiaoao.dataStructure;

import java.util.LinkedList;

/**
 * 基于{@link LinkedList}实现的队列
 *
 * @Author zhangj
 * @Date 2023/2/6 21:37
 */
public class MyLinkedQueue<T> {

    LinkedList<T> list = new LinkedList<>();

    public void enqueue(T e) {
        list.add(e);
    }

    public T dequeue() {
        return list.remove();
    }

    public int size() {
        return list.size();
    }

}
